<?php
//我的■
InitGP(array("action","commit","email","username","oldpassword","password","password2","mobile1","address")); //初始化變量全局返回
if (!empty($commit)) {
	//處理更新用戶資料操作
	if ($password!=$password2) {
		showmessage("兩次輸入密碼不一致！","-1",false);	
	}
	
	
	$editarray=array(
		"tel"=>GetNum($mobile1),
		"address"=>$address
	);
	
	
	include("includes/member.class.php");
	$m=new memberclass();
	$msg=$m->edit($username,$email,$oldpassword,$password,$editarray);
	if ($msg=="OK") {
		showmessage("修改成功！請重新登錄！","login.php",true);
	}else {
		showmessage($msg,"-1",false);	
	}
	
	
}else {
	//顯示資料修改表單
	
/**
 * 輸出測試部分開始


print_r($_USERS);
 */
/**
 * 輸出測試部分結束
 */

	include template('member_settings');//包含輸出指定模板
	
}



?>